package com.appfahrt.persistence.obj.dbo.generated;

import java.util.ArrayList; 
import com.appfahrt.persistence.obj.AbstractDatabaseObject;
import java.sql.Date;
import com.appfahrt.persistence.obj.dao.generated.ProfilGeneratedDao;


/**
 * This Class is automatically generated.<br><br>
 *
 * <u><b>${schema}.profil</b></u><br><br>
 * 
 * <u><b>Table Definition:</b></u>
 * <table> 
 *   <tr> <th>Column-Name</th> <th>Data-Type</th> <th>Data-Length</th> <th>Nullable</th> <th>Description</th> </tr> 
 *   <tr> <td>ID </td> <td>INTEGER</td> <td>-1</td> <td>false</td> <td>-</td> 
 *   <tr> <td>name </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>vorname </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>mobiltelefonnummer </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>telefonnummer </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>email </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>plz </td> <td>integer</td> <td>-1</td> <td>false</td> <td>-</td> 
 *   <tr> <td>ort </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>strasse </td> <td>VARCHAR</td> <td>32</td> <td>false</td> <td>-</td> 
 *   <tr> <td>hausnummer </td> <td>VARCHAR</td> <td>8</td> <td>false</td> <td>-</td> 
 *   <tr> <td>fuehrerschein_seit </td> <td>date</td> <td>-1</td> <td>false</td> <td>-</td> 
 *   <tr> <td>geburtstag </td> <td>date</td> <td>-1</td> <td>false</td> <td>-</td> 
 *   <tr> <td>raucher </td> <td>boolean</td> <td>-1</td> <td>false</td> <td>-</td> 
 *   <tr> <td>umwege </td> <td>boolean</td> <td>-1</td> <td>false</td> <td>-</td> 
 * </table>
 * <br><br>
 * <u><b>References:</b></u> <br>
 *
 * <br><br>
 * <u><b>Indexes:</b></u> <br>
 *
 * <br><b>DON'T MODIFY THIS FILE</b><br><br>
 *
 * Generated: Sun May 22 22:20:17 CEST 2011
 */
public abstract class ProfilGeneratedDbo extends AbstractDatabaseObject {
	
	public static final String TABLE = "profil";
	
	public static final String SCHEMA = "$schema";

	protected ArrayList<String> changedFieldList = new ArrayList<String>();
	
	private boolean loadFromDb = false;

	// Database Column-Definition
	public static final String ID = "id"; 
	public static final String name = "name"; 
	public static final String vorname = "vorname"; 
	public static final String mobiltelefonnummer = "mobiltelefonnummer"; 
	public static final String telefonnummer = "telefonnummer"; 
	public static final String email = "email"; 
	public static final String plz = "plz"; 
	public static final String ort = "ort"; 
	public static final String strasse = "strasse"; 
	public static final String hausnummer = "hausnummer"; 
	public static final String fuehrerschein_seit = "fuehrerschein_seit"; 
	public static final String geburtstag = "geburtstag"; 
	public static final String raucher = "raucher"; 
	public static final String umwege = "umwege"; 
	public final static String[] COLUMNS = {  ID , name , vorname , mobiltelefonnummer , telefonnummer , email , plz , ort , strasse , hausnummer , fuehrerschein_seit , geburtstag , raucher , umwege  };

	// Members
			private Long Id = null;
				private String Name = null;
				private String Vorname = null;
				private String Mobiltelefonnummer = null;
				private String Telefonnummer = null;
				private String Email = null;
				private Long Plz = null;
				private String Ort = null;
				private String Strasse = null;
				private String Hausnummer = null;
				private Date FuehrerscheinSeit = null;
				private Date Geburtstag = null;
				private boolean Raucher = false;
				private boolean Umwege = false;
	
	/** Value-Holder for the references **/
	private References references = new References();
	
	/**
	 * Value-Holder for the references.
	 */
	public class References {


	}

	/**
	 * Constructor.
	 */
	public ProfilGeneratedDbo() {
	
	}
	
	
	/**
	 * Returns the references.
	 */
	public References getReferences() {
		return this.references;
	}
	
	/**
	 * Setter for <b>ID</b>  <br>
	 * Type: INTEGER <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setId(Long Id) {
				if (!(Id == null && this.Id == null) && !this.changedFieldList.contains("ID")) {
			this.changedFieldList.add("ID");
		}
		this.Id = Id ;
			}
	
	/**
	 * Getter for <b>ID</b>  <br>
	 * Type: INTEGER <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public Long getId () {
		return this.Id;
	}
	
	/**
	 * Equals-Method for <b>ID</b>  <br>
	 * Type: INTEGER <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsId(Long Id) {
		boolean result = false;
				if (getId () != null
			&& getId ().equals( Id )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>name</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setName(String Name) {
				if (!(Name == null && this.Name == null) && !this.changedFieldList.contains("name")) {
			this.changedFieldList.add("name");
		}
		this.Name = Name ;
			}
	
	/**
	 * Getter for <b>name</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getName () {
		return this.Name;
	}
	
	/**
	 * Equals-Method for <b>name</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsName(String Name) {
		boolean result = false;
				if (getName () != null
			&& getName ().equals( Name )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>vorname</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setVorname(String Vorname) {
				if (!(Vorname == null && this.Vorname == null) && !this.changedFieldList.contains("vorname")) {
			this.changedFieldList.add("vorname");
		}
		this.Vorname = Vorname ;
			}
	
	/**
	 * Getter for <b>vorname</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getVorname () {
		return this.Vorname;
	}
	
	/**
	 * Equals-Method for <b>vorname</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsVorname(String Vorname) {
		boolean result = false;
				if (getVorname () != null
			&& getVorname ().equals( Vorname )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>mobiltelefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setMobiltelefonnummer(String Mobiltelefonnummer) {
				if (!(Mobiltelefonnummer == null && this.Mobiltelefonnummer == null) && !this.changedFieldList.contains("mobiltelefonnummer")) {
			this.changedFieldList.add("mobiltelefonnummer");
		}
		this.Mobiltelefonnummer = Mobiltelefonnummer ;
			}
	
	/**
	 * Getter for <b>mobiltelefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getMobiltelefonnummer () {
		return this.Mobiltelefonnummer;
	}
	
	/**
	 * Equals-Method for <b>mobiltelefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsMobiltelefonnummer(String Mobiltelefonnummer) {
		boolean result = false;
				if (getMobiltelefonnummer () != null
			&& getMobiltelefonnummer ().equals( Mobiltelefonnummer )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>telefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setTelefonnummer(String Telefonnummer) {
				if (!(Telefonnummer == null && this.Telefonnummer == null) && !this.changedFieldList.contains("telefonnummer")) {
			this.changedFieldList.add("telefonnummer");
		}
		this.Telefonnummer = Telefonnummer ;
			}
	
	/**
	 * Getter for <b>telefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getTelefonnummer () {
		return this.Telefonnummer;
	}
	
	/**
	 * Equals-Method for <b>telefonnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsTelefonnummer(String Telefonnummer) {
		boolean result = false;
				if (getTelefonnummer () != null
			&& getTelefonnummer ().equals( Telefonnummer )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>email</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setEmail(String Email) {
				if (!(Email == null && this.Email == null) && !this.changedFieldList.contains("email")) {
			this.changedFieldList.add("email");
		}
		this.Email = Email ;
			}
	
	/**
	 * Getter for <b>email</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getEmail () {
		return this.Email;
	}
	
	/**
	 * Equals-Method for <b>email</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsEmail(String Email) {
		boolean result = false;
				if (getEmail () != null
			&& getEmail ().equals( Email )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>plz</b>  <br>
	 * Type: integer <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setPlz(Long Plz) {
				if (!(Plz == null && this.Plz == null) && !this.changedFieldList.contains("plz")) {
			this.changedFieldList.add("plz");
		}
		this.Plz = Plz ;
			}
	
	/**
	 * Getter for <b>plz</b>  <br>
	 * Type: integer <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public Long getPlz () {
		return this.Plz;
	}
	
	/**
	 * Equals-Method for <b>plz</b>  <br>
	 * Type: integer <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsPlz(Long Plz) {
		boolean result = false;
				if (getPlz () != null
			&& getPlz ().equals( Plz )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>ort</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setOrt(String Ort) {
				if (!(Ort == null && this.Ort == null) && !this.changedFieldList.contains("ort")) {
			this.changedFieldList.add("ort");
		}
		this.Ort = Ort ;
			}
	
	/**
	 * Getter for <b>ort</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getOrt () {
		return this.Ort;
	}
	
	/**
	 * Equals-Method for <b>ort</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsOrt(String Ort) {
		boolean result = false;
				if (getOrt () != null
			&& getOrt ().equals( Ort )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>strasse</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setStrasse(String Strasse) {
				if (!(Strasse == null && this.Strasse == null) && !this.changedFieldList.contains("strasse")) {
			this.changedFieldList.add("strasse");
		}
		this.Strasse = Strasse ;
			}
	
	/**
	 * Getter for <b>strasse</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getStrasse () {
		return this.Strasse;
	}
	
	/**
	 * Equals-Method for <b>strasse</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 32 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsStrasse(String Strasse) {
		boolean result = false;
				if (getStrasse () != null
			&& getStrasse ().equals( Strasse )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>hausnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 8 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setHausnummer(String Hausnummer) {
				if (!(Hausnummer == null && this.Hausnummer == null) && !this.changedFieldList.contains("hausnummer")) {
			this.changedFieldList.add("hausnummer");
		}
		this.Hausnummer = Hausnummer ;
			}
	
	/**
	 * Getter for <b>hausnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 8 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public String getHausnummer () {
		return this.Hausnummer;
	}
	
	/**
	 * Equals-Method for <b>hausnummer</b>  <br>
	 * Type: VARCHAR <br>
	 * Length: 8 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsHausnummer(String Hausnummer) {
		boolean result = false;
				if (getHausnummer () != null
			&& getHausnummer ().equals( Hausnummer )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>fuehrerschein_seit</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setFuehrerscheinSeit(Date FuehrerscheinSeit) {
				if (!(FuehrerscheinSeit == null && this.FuehrerscheinSeit == null) && !this.changedFieldList.contains("fuehrerschein_seit")) {
			this.changedFieldList.add("fuehrerschein_seit");
		}
		this.FuehrerscheinSeit = FuehrerscheinSeit ;
			}
	
	/**
	 * Getter for <b>fuehrerschein_seit</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public Date getFuehrerscheinSeit () {
		return this.FuehrerscheinSeit;
	}
	
	/**
	 * Equals-Method for <b>fuehrerschein_seit</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsFuehrerscheinSeit(Date FuehrerscheinSeit) {
		boolean result = false;
				if (getFuehrerscheinSeit () != null
			&& getFuehrerscheinSeit ().equals( FuehrerscheinSeit )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>geburtstag</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setGeburtstag(Date Geburtstag) {
				if (!(Geburtstag == null && this.Geburtstag == null) && !this.changedFieldList.contains("geburtstag")) {
			this.changedFieldList.add("geburtstag");
		}
		this.Geburtstag = Geburtstag ;
			}
	
	/**
	 * Getter for <b>geburtstag</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public Date getGeburtstag () {
		return this.Geburtstag;
	}
	
	/**
	 * Equals-Method for <b>geburtstag</b>  <br>
	 * Type: date <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsGeburtstag(Date Geburtstag) {
		boolean result = false;
				if (getGeburtstag () != null
			&& getGeburtstag ().equals( Geburtstag )) {
			result = true;
		}
				return result;
	} 
	/**
	 * Setter for <b>raucher</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setRaucher(boolean Raucher) {
				this.Raucher = Raucher ;
			}
	
	/**
	 * Getter for <b>raucher</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean getRaucher () {
		return this.Raucher;
	}
	
	/**
	 * Equals-Method for <b>raucher</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsRaucher(boolean Raucher) {
		boolean result = false;
				result = getRaucher ()==Raucher;
				return result;
	} 
	/**
	 * Setter for <b>umwege</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public void setUmwege(boolean Umwege) {
				this.Umwege = Umwege ;
			}
	
	/**
	 * Getter for <b>umwege</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean getUmwege () {
		return this.Umwege;
	}
	
	/**
	 * Equals-Method for <b>umwege</b>  <br>
	 * Type: boolean <br>
	 * Length: -1 <br>
	 * Nullable: false <br>
	 * Comment: - <br>
	 */
	public boolean equalsUmwege(boolean Umwege) {
		boolean result = false;
				result = getUmwege ()==Umwege;
				return result;
	} 

	/**
	 * Returns a short String with the values.
	 */
	public String toInfoShortString() {
		return  "[ID=" + this.Id+"]" +"-[name="+this.Name + "]" +"-[vorname="+this.Vorname + "]" +"-[mobiltelefonnummer="+this.Mobiltelefonnummer + "]" +"-[telefonnummer="+this.Telefonnummer + "]" +"-[email="+this.Email + "]" +"-[plz="+this.Plz + "]" +"-[ort="+this.Ort + "]" +"-[strasse="+this.Strasse + "]" +"-[hausnummer="+this.Hausnummer + "]" +"-[fuehrerschein_seit="+this.FuehrerscheinSeit + "]" +"-[geburtstag="+this.Geburtstag + "]" +"-[raucher="+this.Raucher + "]" +"-[umwege="+this.Umwege + "]" ;
	}
	
	/**
	 * Returns a Comma-Separated Values (CSV) String. <br>
	 * Separator: ;
	 */
	public String toCsvString() {
		return toCsvString(";");
	}
	
	/**
	 * Returns a Comma-Separated Values (CSV) String
	 * with the given separator.
	 */
	public String toCsvString(String separator) {
		return  this.Id+separator+this.Name+separator+this.Vorname+separator+this.Mobiltelefonnummer+separator+this.Telefonnummer+separator+this.Email+separator+this.Plz+separator+this.Ort+separator+this.Strasse+separator+this.Hausnummer+separator+this.FuehrerscheinSeit+separator+this.Geburtstag+separator+this.Raucher+separator+this.Umwege;
	}
	
	/**
	 * Indicates whether the object has 
	 * changed or not.
	 */
	public boolean hasChanged() {
		return this.changedFieldList.size() > 0;
	}
	
	/**
	 * Changes Fields.
	 */
	public ArrayList<String> getChangedFieldList() {
		return this.changedFieldList;
	}
	
	/**
	 * Indicates, whether the object is new 
	 * or exists in the database.
	 */ 
	public boolean isNew() {
		return !loadFromDb;
	}
	
	/**
	 * Returns the name of the corresponding database table.
	 */
	public String getTable() {
		return TABLE;
	}
	
	/**
	 * Returns the name of the corresponding database schema.
	 */
	public String getSchema() {
		return SCHEMA;
	}
}